/**
 * 
 */
//afdsadfadsf
function doSum(){
	var count = document.getElementById("num").value;
	var sum = 0;
	for(var i=1;i<=count;i++){
		sum+=i;
	}
	document.getElementsByName("temp")[0].value=sum;	
}

//doSum();

function beforeSub(){
	var txtUserName = document.getElementsByName("userName")[0];
	if(txtUserName.value == ""){
		alert("姓名为必填项");
		txtUserName.focus();
		return false;
	}
	return true;
}

function doSubPage(){
	if(beforeSub()){
		document.forms[0].submit();	
	}
	
}
function goUrl(){
	location.href = "infoGetEnd.jsp";
}












